package nowCoder;

import java.util.Scanner;

/**
 * @Auther: zzx
 * @Date: 2024.03.24/3/6
 */
public class HJ108 {
    // 12 18 3 2 2  2 3 3  2 2 3 3 36
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int x = sc.nextInt();
        int y = sc.nextInt();
        for (int i = 1; i <= x; i++) {
            if (y*i % x == 0){
                System.out.println(y*i);
                return;
            }
        }
    }
}
